Optimal. Leaf size=64 \[ -\frac {(a+b) (A+B) \log (1-\sin (c+d x))}{2 d}+\frac {(a-b) (A-B) \log (\sin (c+d x)+1)}{2 d}-\frac {b B \sin (c+d x)}{d} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.11, antiderivative size = 64, normalized size of antiderivative = 1.00, number of steps used = 5, number of rules used = 4, integrand size = 27, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.148, Rules used = {2837, 774, 633, 31} \[ -\frac {(a+b) (A+B) \log (1-\sin (c+d x))}{2 d}+\frac {(a-b) (A-B) \log (\sin (c+d x)+1)}{2 d}-\frac {b B \sin (c+d x)}{d} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 31
Rule 633
Rule 774
Rule 2837
Rubi steps
\begin {align*} \int \sec (c+d x) (a+b \sin (c+d x)) (A+B \sin (c+d x)) \, dx &=\frac {b \operatorname {Subst}\left (\int \frac {(a+x) \left (A+\frac {B x}{b}\right )}{b^2-x^2} \, dx,x,b \sin (c+d x)\right )}{d}\\ &=-\frac {b B \sin (c+d x)}{d}-\frac {b \operatorname {Subst}\left (\int \frac {-a A-b B-\left (A+\frac {a B}{b}\right ) x}{b^2-x^2} \, dx,x,b \sin (c+d x)\right )}{d}\\ &=-\frac {b B \sin (c+d x)}{d}-\frac {((a-b) (A-B)) \operatorname {Subst}\left (\int \frac {1}{-b-x} \, dx,x,b \sin (c+d x)\right )}{2 d}+\frac {((a+b) (A+B)) \operatorname {Subst}\left (\int \frac {1}{b-x} \, dx,x,b \sin (c+d x)\right )}{2 d}\\ &=-\frac {(a+b) (A+B) \log (1-\sin (c+d x))}{2 d}+\frac {(a-b) (A-B) \log (1+\sin (c+d x))}{2 d}-\frac {b B \sin (c+d x)}{d}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A] time = 0.03, size = 68, normalized size = 1.06 \[ \frac {a A \tanh ^{-1}(\sin (c+d x))}{d}-\frac {a B \log (\cos (c+d x))}{d}-\frac {A b \log (\cos (c+d x))}{d}-\frac {b B \sin (c+d x)}{d}+\frac {b B \tanh ^{-1}(\sin (c+d x))}{d} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [A] time = 0.47, size = 66, normalized size = 1.03 \[ -\frac {2 \, B b \sin \left (d x + c\right ) - {\left ({\left (A - B\right )} a - {\left (A - B\right )} b\right )} \log \left (\sin \left (d x + c\right ) + 1\right ) + {\left ({\left (A + B\right )} a + {\left (A + B\right )} b\right )} \log \left (-\sin \left (d x + c\right ) + 1\right )}{2 \, d} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [A] time = 0.17, size = 67, normalized size = 1.05 \[ -\frac {2 \, B b \sin \left (d x + c\right ) - {\left (A a - B a - A b + B b\right )} \log \left ({\left | \sin \left (d x + c\right ) + 1 \right |}\right ) + {\left (A a + B a + A b + B b\right )} \log \left ({\left | \sin \left (d x + c\right ) - 1 \right |}\right )}{2 \, d} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [A] time = 0.36, size = 83, normalized size = 1.30 \[ \frac {a A \ln \left (\sec \left (d x +c \right )+\tan \left (d x +c \right )\right )}{d}-\frac {A b \ln \left (\cos \left (d x +c \right )\right )}{d}-\frac {b B \sin \left (d x +c \right )}{d}+\frac {B b \ln \left (\sec \left (d x +c \right )+\tan \left (d x +c \right )\right )}{d}-\frac {a B \ln \left (\cos \left (d x +c \right )\right )}{d} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [A] time = 0.31, size = 64, normalized size = 1.00 \[ -\frac {2 \, B b \sin \left (d x + c\right ) - {\left ({\left (A - B\right )} a - {\left (A - B\right )} b\right )} \log \left (\sin \left (d x + c\right ) + 1\right ) + {\left ({\left (A + B\right )} a + {\left (A + B\right )} b\right )} \log \left (\sin \left (d x + c\right ) - 1\right )}{2 \, d} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 0.12, size = 53, normalized size = 0.83 \[ -\frac {B\,b\,\sin \left (c+d\,x\right )-\frac {\ln \left (\sin \left (c+d\,x\right )+1\right )\,\left (A-B\right )\,\left (a-b\right )}{2}+\frac {\ln \left (\sin \left (c+d\,x\right )-1\right )\,\left (a+b\right )\,\left (A+B\right )}{2}}{d} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [F] time = 0.00, size = 0, normalized size = 0.00 \[ \int \left (A + B \sin {\left (c + d x \right )}\right ) \left (a + b \sin {\left (c + d x \right )}\right ) \sec {\left (c + d x \right )}\, dx \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________